import sqlalchemy as sql

dbpath = "/Users/hhwang/code/gitee/haihwang/langgraph-examples/data_science/database"
# sql_engine = sql.create_engine(f"sqlite:///{dbpath}/northwind.db")
sql_engine = sql.create_engine(
    "postgresql+psycopg2://postgres:postgres@localhost:5433/starhub_server",
    pool_size=10,  # 连接池大小
    max_overflow=5,  # 最大溢出连接数
    pool_timeout=30,  # 连接超时时间(秒)
    pool_recycle=3600  # 连接回收时间(秒)
)
connection = sql_engine.connect()